import * as api from './api'

export const install = (app, { components = {} } = {}) => {
  for (const key in api) {
    app.config.globalProperties[key] = api[key]
  }

  Object.entries(components).forEach(([name, component]) => {
    app.component(name, component)
  })
}

export * from './api'
